import request from '@/utils/request'

// 查询多点位温度列表
export function listMoreTemperatureData(query) {
  return request({
    url: '/baseinfo/moreTemperatureData/list',
    method: 'get',
    params: query
  })
}

// 查询多点位温度列表
export function getTemperatureChartData(query) {
  return request({
    url: '/baseinfo/moreTemperatureData/getTemperatureChartData',
    method: 'get',
    params: query
  })
}

// 查询多点位温度列表
export function getTemperatureChartDataIndex(query) {
  return request({
    url: '/baseinfo/moreTemperatureData/getTemperatureChartDataIndex',
    method: 'get',
    params: query
  })
}
export function getLastTemp(equipmentCode) {
  return request({
    url: '/baseinfo/moreTemperatureData/getLastTemp/'+equipmentCode,
    method: 'get'
  })
}


// 查询多点位温度详细
export function getMoreTemperatureData(id) {
  return request({
    url: '/baseinfo/moreTemperatureData/' + id,
    method: 'get'
  })
}

// 新增多点位温度
export function addMoreTemperatureData(data) {
  return request({
    url: '/baseinfo/moreTemperatureData',
    method: 'post',
    data: data
  })
}

// 新增多点位温度
export function calculation(data) {
  return request({
    url: '/baseinfo/moreTemperatureData/calculation',
    method: 'post',
    data: data
  })
}



// 修改多点位温度
export function updateMoreTemperatureData(data) {
  return request({
    url: '/baseinfo/moreTemperatureData',
    method: 'put',
    data: data
  })
}

// 删除多点位温度
export function delMoreTemperatureData(id) {
  return request({
    url: '/baseinfo/moreTemperatureData/' + id,
    method: 'delete'
  })
}
